﻿<sdk:ChildWindow x:Class="Apps.Yunwei.Views.RoleDetail"
                 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                 xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
                 Style="{StaticResource MetroChildWindow}"
                 Title="角色信息" Width="640" Height="400">
    <Grid x:Name="LayoutRoot">
        <Grid.Resources>
            <Style TargetType="TextBlock" BasedOn="{StaticResource DefaultTextBlock}">
                <Setter Property="VerticalAlignment" Value="Top"/>
                <Setter Property="TextAlignment" Value="Right"/>
                <Setter Property="Margin" Value="2,6,4,0" />
            </Style>
            <Style TargetType="TextBox" BasedOn="{StaticResource DefaultTextBox}">
                <Setter Property="MinHeight" Value="28"/>
                <Setter Property="TextWrapping" Value="Wrap"/>
                <Setter Property="Margin" Value="2,2,0,4" />
            </Style>
        </Grid.Resources>
        <Grid.RowDefinitions>
            <RowDefinition />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <Grid Grid.RowSpan="2" Margin="0,0,16,0">
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto" MinHeight="36"/>
                <RowDefinition Height="Auto" MinHeight="36"/>
                <RowDefinition Height="Auto" MinHeight="36"/>
                <RowDefinition Height="Auto" MinHeight="36"/>
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="Auto" MinWidth="85"/>
                <ColumnDefinition Width="*"/>
            </Grid.ColumnDefinitions>
            <TextBlock Text="代码"/>
            <TextBlock Text="标题" Grid.Row="1"/>
            <TextBlock Text="描述" Grid.Row="2"/>
            <TextBox Grid.Column="1" Margin="2,2,0,4"
                     Text="{Binding Code, Mode=TwoWay, ValidatesOnDataErrors=true}"/>
            <TextBox Grid.Column="1" Grid.Row="1" 
                     Text="{Binding Caption, Mode=TwoWay, ValidatesOnDataErrors=true}"/>
            <TextBox Grid.Column="1" Grid.Row="2" 
                     Text="{Binding Describe, Mode=TwoWay, ValidatesOnDataErrors=true}"/>
        </Grid>
        <Button x:Name="OKButton" Content="确定" Click="OKButton_Click" Width="75" Height="23" Margin="0,0,79,0" HorizontalAlignment="Right" Grid.Row="1"/>
        <Button x:Name="CancelButton" Content="取消" Click="CancelButton_Click" Width="75" Height="23" HorizontalAlignment="Right" Grid.Row="1"/>
    </Grid>
</sdk:ChildWindow>